﻿namespace SuperMarieApi.App.Controllers.Framework.Config.DataAccess
{
    using System.Configuration;

    public class DataAccessConfig : ConfigurationSection
    {
        [ConfigurationProperty("databaseFile", IsRequired = true)]
        public string DatabaseFile
        {
            get
            {
                return base["databaseFile"] as string;
            }
            set
            {
                base["databaseFile"] = value;
            }
        }

        [ConfigurationProperty("dataConfigDir", IsRequired = true)]
        public string DataConfigDir
        {
            get
            {
                return base["dataConfigDir"] as string;
            }
            set
            {
                base["dataConfigDir"] = value;
            }
        }

        [ConfigurationProperty("pageSizeDefault", DefaultValue = 20)]
        public int PageSizeDefault
        {
            get
            {
                return (int)base["pageSizeDefault"];
            }
            set
            {
                base["pageSizeDefault"] = value;
            }
        }

        [ConfigurationProperty("pageIndexStart", DefaultValue = 0)]
        public int PageIndexStart
        {
            get
            {
                return (int)base["pageIndexStart"];
            }
            set
            {
                base["pageIndexStart"] = value;
            }
        }
    }
}
